@php
$key_cn = [
'step1_jine'=>'诉请金额',
'step1_riqi'=>'立案日期',
'step1_sudiao'=>'诉调号',
'step1_fayuan'=>'立案法院',
'step2_riqi'=>'缴费日期',
'step2_anhao'=>'案号',
'step3_fangshi'=>'送达方式',
'step3_riqi'=>'送达日期',
'step3_kaiting'=>'开庭日期',
'step3_faguan'=>'审理法官',
'step4_riqi'=>'判决日期',
'step4_jine'=>'判决金额',
'step4_jieguo'=>'判决结果',
'step4_faguan'=>'执行法官',
'step5_tiaojie'=>'调解日期',
'step5_jieguo'=>'调解结果',
'step6_beizhu'=>'调解结果',
'step7_anhao'=>'执行案号',
'step7_faguan'=>'执行法官',
'step7_lianxi'=>'联系方式',
'step8_beizhu'=>'备注',
'step9_jieguo'=>'判决结果',
'step9_beizhu'=>'备注',
]
@endphp

@if ($caseprogress->count())
@foreach ($caseprogress as $progress)
<div class="card">

    <div class="card-header">
        @switch($progress['trial_step'])
        @case(1)
        立案
        @break
        @case(2)
        缴费
        @break
        @case(3)
        传票
        @break
        @case(4)
        判决
        @break
        @case(5)
        调解
        @break
        @case(6)
        申请执行
        @break
        @case(7)
        立案执行
        @break
        @case(8)
        撤案
        @break
        @case(9)
        结案
        @break
        @default
        意外终止
        @endswitch
        <span class="badge badge-primary">
        @if ($progress['trial_num'] != 3)
        {{$progress['trial_num']}}审
        @else
        仲裁
        @endif</span>
    </div>

    <div class="card-body chunked_content">
        <div class="row">
            {{-- {{dd()}} --}}
            @foreach (json_decode($progress['content']) as $k=>$v)
            <div class="col-md-4">
                {{-- {{dd($v)}} --}}
                <div><span class="fw-bold">{{$key_cn[$k]}}:   </span><span class="content_value">{{($k == 'step9_jieguo')?(($v == 1)?('胜诉'):('败诉')):($v)}}</span></div>
            </div>
            @endforeach
        </div>
    </div>
</div>

@endforeach

@else
<x-blank_tips>
    <x-slot name="title">
        本案件目前没有任何进展
    </x-slot>
    点击顶部操作按钮添加案件进度<br>或联系负责律师完善进度
</x-blank_tips>
@endif
